Skip to content

Streamline apt packages installed in CI - #8524

Merged
mhucka merged 6 commits into
quantumlib:mainfrom
mhucka:streamline-ci-installations
Nov 10, 2026
Merged

mhucka merged 6 commits into
quantumlib:mainfrom
mhucka:streamline-ci-installations

Conversation

@mhucka

@mhucka mhucka commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

The python3-tk package is vestigial in CI (PR #1876): it installs Tkinter for Ubuntu's system Python 3.10, whereas actions/setup-python runs Python 3.11–3.14 from /opt/hostedtoolcache, which already bundles _tkinter. We can remove it from apt-system-requirements.txt

In addition, if we add the latexmk, poppler-utils, and lmodern packages explicitly to apt-system-requirements.txt, we can use the --no-install-recommends option to apt install in CI, which will reduce by roughly half of the 168 MB it currently downloads.

The python3-tk package is vestigial in CI (PR quantumlib#1876): it installs Tkinter
for Ubuntu's system Python 3.10, whereas actions/setup-python runs
Python 3.11–3.14 from /opt/hostedtoolcache, which already bundles
_tkinter. We can remove it from apt-system-requirements.txt

In addition, if we add latexmk and poppler-utils explicitly, we can use
the `--no-install-recommends` option to `apt install` in CI, which will
reduce by roughly half 168 MB download it's currently doing for apt
installing apt-system-requirements.txt.
As it was, `apt-get install apt-system-requirements.txt` pulled in large
recommended font/doc/X11-viewer packages on every Changed files test,
Coverage check, and Pytest Ubuntu job. By adjusting
apt-system-requirements.txt and using `--no-install-recommends`, we can
greatly reduce what needs to be downloaded and installed.
@github-actions github-actions Bot added the size: S 10< lines changed <50 label Nov 10, 2026
As it was, `apt-get install apt-system-requirements.txt` pulled in large
recommended font/doc/X11-viewer packages on every Changed files test,
Coverage check, and Pytest Ubuntu job. By adjusting
apt-system-requirements.txt and using `--no-install-recommends`, we can
greatly reduce what needs to be downloaded and installed.
@codecov

codecov Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.58%. Comparing base (26a5ee6) to head (5538987).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8524      +/-   ##
==========================================
- Coverage   99.58%   99.58%   -0.01%     
==========================================
  Files        1137     1137              
  Lines      105158   105158              
==========================================
- Hits       104723   104719       -4     
- Misses        435      439       +4     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mhucka
mhucka marked this pull request as ready for review November 10, 2026 22:26
@mhucka
mhucka requested a review from a team as a code owner November 10, 2026 22:26
@mhucka
mhucka requested review from arettig and pavoljuhas November 10, 2026 22:26
Comment thread .github/workflows/ci-daily.yml Outdated
run: |
sudo apt-get update
sudo apt-get install $(cat apt-system-requirements.txt)
sudo apt-get install --no-install-recommends -y $(cat apt-system-requirements.txt)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you confirm this needs the -y option here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hard to test locally. I'll remove it and see what happens in GitHub CI.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you confirm this needs the -y option here?

Looks like it works without -y. Hmmmm … I'm going to try removing it everywhere and see if it still works.

@mhucka mhucka Nov 10, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pavoljuhas You're right; the flag is not needed.

Updated this PR to omit the flag. Thanks for noticing that!

@pavoljuhas pavoljuhas left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice improvement! Please see an optional comment before merge.

@pavoljuhas
pavoljuhas added this pull request to the merge queue Nov 10, 2026
@mhucka
mhucka removed this pull request from the merge queue due to a manual request Nov 10, 2026
@mhucka
mhucka enabled auto-merge November 10, 2026 23:31
@mhucka
mhucka added this pull request to the merge queue Nov 10, 2026
Merged via the queue into quantumlib:main with commit 493d0b4 Nov 10, 2026
48 of 49 checks passed
@mhucka
mhucka deleted the streamline-ci-installations branch November 10, 2026 23:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: S 10< lines changed <50

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants